__autho__ = "付鹏飞"

import turtle
import math

'''
绘制小人的路径图，求出出发地与终点距离
'''
if __name__ == "__main__":
    x1, y1 = 100, 100
    x2, y2 = 100, -100
    x3, y3 = -100, -100
    x4, y4 = -100, 100

    turtle.penup()
    turtle.goto(x1, y1)
    turtle.pendown()
    turtle.goto(x2, y2)
    turtle.goto(x3, y3)
    turtle.goto(x4, y4)

    distance = math.sqrt((x1 - x4) ** 2 + (y1 - y4) ** 2)
    turtle.write(distance)

    turtle.done()
